package com.ghp.common.model.dto.user;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;

import static com.ghp.common.constants.ErrorMessageConstants.ACCOUNT_NOT_BLANK;
import static com.ghp.common.constants.ErrorMessageConstants.PASSWORD_NOT_BLANK;

/**
 * 用户登录请求
 */
@ApiModel(description = "用户登录信息")
@Data
public class UserLoginDTO implements Serializable {

    private static final long serialVersionUID = 3191241716373120793L;
    /**
     * 用户账号
     */
    @ApiModelProperty(value = "用户账号", example = "admin", required = true)
    @NotBlank(message = ACCOUNT_NOT_BLANK)
    private String userAccount;
    /**
     * 用户密码
     */
    @ApiModelProperty(value = "用户账号", example = "admin123", required = true)
    @NotBlank(message = PASSWORD_NOT_BLANK)
    private String userPassword;
}
